import http from '@/utils/request'

/**
 * 登录请求接口功能
 * @param {*} data {mobile, password}
 */
export function reqLogin(data) {
  return http({
    url: '/sys/login',
    method: 'post',
    data
  })
}

/**
 * 获取用户基本资料(需要token)
 */
export const reqGetProfile = () => {
  return http({
    url: '/sys/profile',
    method: 'post'
  })
}

/**
 * 获取员工基本信息
 * @param {*} id 员工id
 */
export const reqGetBaseInfo = (id) => {
  return http({
    method: 'get',
    url: `/sys/user/${id}`
  })
}

/**
 * 获取员工简单列表
 */
export const reqGetSimpleUserList = () => http({ url: '/sys/user/simple' })

// export const reqGetSimpleUserList = () => {
//   return http({
//     method: 'get',
//     url: '/sys/user/simple'
//   })
// }
